package com.tianfeng.huayi.service.impl;

import com.tianfeng.huayi.entity.ParkingSpace;
import com.tianfeng.huayi.entity.Vehicle;
import com.tianfeng.huayi.mapper.ParkingSpaceMapper;
import com.tianfeng.huayi.service.IParkingSpaceService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class ParkingSpaceServiceImpl implements IParkingSpaceService {

    @Autowired
    private ParkingSpaceMapper parkingSpaceMapper;

    @Override
    public ParkingSpace selectParkingSpaceBySpaceId(Long spaceId) {
        return parkingSpaceMapper.selectParkingSpaceBySpaceId(spaceId);
    }

    @Override
    public List<ParkingSpace> selectParkingSpaceList(ParkingSpace parkingSpace) {
        return parkingSpaceMapper.selectParkingSpaceList(parkingSpace);
    }

    @Override
    public Vehicle selectVehicleByVehicleId(Long vehicleId) {
        return parkingSpaceMapper.selectVehicleByVehicleId(vehicleId);
    }

    @Override
    public List<Vehicle> selectVehicleList(Vehicle vehicle) {
        return parkingSpaceMapper.selectVehicleList(vehicle);
    }
}
